# coding: utf-8
from application import db


class WalletInfo(db.Model):
    __tablename__ = 'wallet_info'

    id = db.Column(db.BigInteger, primary_key=True, unique=True, comment='序号')
    userAddress = db.Column(db.String(500), comment='用户地址')
    price = db.Column(db.Numeric(10, 2), comment='价格')
    pay_sn = db.Column(db.String(128), comment='第三方流水号')
    prepay_id = db.Column(db.String(128), comment='第三方预付id')
    blocknum = db.Column(db.Integer, nullable=False, comment='块高')
    blockHash = db.Column(db.String(300), nullable=False, unique=True, comment='块哈希')
    transactionhash = db.Column(db.String(300), nullable=False, unique=True, comment='交易哈希')
    status = db.Column(db.Integer, comment='状态')
    type = db.Column(db.Integer, comment='类型')
    note = db.Column(db.String(200), comment='备注信息')
    updated_time = db.Column(db.DateTime, nullable=False, comment='更新时间')
    created_time = db.Column(db.DateTime, nullable=False, comment='创建时间')
